package com.ladlee.parking.pay.v3.enums;

import cn.hutool.core.util.ObjectUtil;

/**
 * <p>微信支付方式</p>
 */
public enum AliTradeType {
    /**
     * 支付宝APP支付
     */
    APP("APP");

    AliTradeType(String tradeType) {
        this.tradeType = tradeType;
    }

    /**
     * 交易类型
     */
    private final String tradeType;

    public String getTradeType() {
        return tradeType;
    }

    public static Boolean validation(String tradeType) {
        for (AliTradeType value : AliTradeType.values()) {
            if (ObjectUtil.equal(value.tradeType, tradeType)) {
                return true;
            }
        }
        return false;
    }
}
